﻿using System.ComponentModel.DataAnnotations;

namespace Lumos.Models
{
    public class Users
    {
        [Key]
        public string Id { get; set; }

        [Required]
        [EmailAddress]
        [Display(Name = "Email")]
        public string Email { get; set; }

        [Required]
        [StringLength(100, ErrorMessage = "The {0} must be at least {2} characters long.", MinimumLength = 6)]
        [DataType(DataType.Password)]
        [Display(Name = "Password")]
        public string PasswordHash { get; set; }

        [DataType(DataType.Password)]
        [Display(Name = "Confirm password")]
        [Compare("Password", ErrorMessage = "The password and confirmation password do not match.")]
        public string ConfirmPassword { get; set; }
        
        [Required]
        [StringLength(250, ErrorMessage = "User name is required")]
        [DataType(DataType.Text)]
        [Display(Name = "Name")]
        public string UserName { get; set; }

        [DataType(DataType.PhoneNumber)]
        [StringLength(15, ErrorMessage="Phone number cannot exceed 15 characters")]
        [Display(Name="Extension")]
        public string PrimaryPhoneNumber { get; set; }

        [DataType(DataType.PhoneNumber)]
        [StringLength(15, ErrorMessage = "Mobile number cannot exceed 15 characters")]
        [Display(Name = "Mobile")]
        public string MobilePhoneNumber { get; set; }

        [DataType(DataType.PhoneNumber)]
        [StringLength(15, ErrorMessage = "Alternate phone number cannot exceed 15 characters")]
        [Display(Name="Alternate Phone Number")]
        public string AlternatePhoneNumber { get; set; }

        [Display(Name="Location")]
        public string WorkLocation { get; set; }

        [Display(Name="Country")]
        public string WorkCountry { get; set; }
        
    }
}